//
//  WZDepListCell.m
//  wanzhaoIM
//
//  Created by wanzhao on 16/1/11.
//  Copyright © 2016年 liuyuantao. All rights reserved.
//

#import "WZDepListCell.h"

@implementation WZDepListCell

+ (WZDepListCell *)depListCellWithTableView:(UITableView *)tableView
{
    static NSString *depcellId = @"depListCellID";
    WZDepListCell *cell = [tableView dequeueReusableCellWithIdentifier:depcellId];
    if (cell == nil) {
        cell = [[WZDepListCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:depcellId];
        cell.textLabel.textAlignment = UITextAlignmentCenter;
        cell.backgroundColor = ClearColor;
        cell.textLabel.font = [UIFont systemFontOfSize:16.0f];
    }
    return cell;
}

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        
        [self setupViews];
    }
    return self;
}

- (void)setupViews
{
    UIImageView *line = [[UIImageView alloc] init];
    line.image = [UIImage imageNamed:@"BG-line"];
    [self.contentView addSubview:line];
    self.sepreateLine = line;
}

- (void)layoutSubviews
{
    [super layoutSubviews];
    self.sepreateLine.frame = CGRectMake(0, self.frame.size.height - 1.5f, self.frame.size.width, 1.5f);
}
@end

